package fr.afcepf.atod19.voyage.service.implementation;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import fr.afcepf.atod19.voyage.dao.interfaces.IDataVoyage;
import fr.afcepf.atod19.voyage.entities.Voyage;
import fr.afcepf.atod19.voyage.service.interfaces.IServiceVoyage;
@Component
public class ServiceVoyage implements IServiceVoyage {
	
	@Autowired
	private IDataVoyage daoVoyage; 
	
	@Override
	public Voyage creerUnVoyage(Voyage v) {
		return daoVoyage.ajouterVoyage(v);
	}

	@Override
	public Voyage modifierUnVoyage(Voyage v) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public boolean supprimerUnVoyage(Voyage v) {
		return daoVoyage.supprimerVoyage(v);
	}

	@Override
	public List<Voyage> rechercherVoyage(Voyage v) {
		return daoVoyage.rechercherVoyage(v);
	}

	@Override
	public Voyage consulterUnVoyage(Integer numVoyage) {
		return daoVoyage.consulterVoyage(numVoyage);
	}

}
